<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
		<title>OA协同办公</title>
		<link rel="stylesheet" type="text/css" href="css/table.css">
		 <link rel="stylesheet" href="js/easyui/themes/default/easyui.css" />
	    <link rel="stylesheet" href="js/easyui/themes/icon.css" />
	   <script type="text/javascript" src="js/easyui/jquery-1.4.4.min.js"></script>
      <script type="text/javascript" src="js/easyui/jquery.easyui.min.js"></script>
		<script type="text/javascript">
		window.onload=function loadTree(){
             $('#tt2').tree({   
                  checkbox: false,   
                 url: 'organizationTree.action',   
                  onBeforeExpand:function(node,param){
                      $('#tt2').tree('options').url = "organizationChildTree.action?orgId="+ node.id;// change the url                       
                     
                  },               
                  onClick:function(node){
					  $(this).tree('toggle', node.target); 
                       getOrg(node.id);
                  }   
              });   
         }
		

function getOrg(id){
	$("#mainFrame").attr("src","getOrgListById.action?orgId="+id);
}
</script>
	</head>
	<body  >
		<table width="100%">
			<tr>
				<td width="200px">
					<div id="tree-div" style="margin:0; width: 200px; height: 450px; overflow:scroll;  border: #c3daf9 double 1px;">
                    <ul id="tt2">
                    
			          </ul>
			      </div>

				</td>
				<td  width="100%" valign="top" height="450px">
							<iframe scrolling="yes" id="mainFrame" name="mainFrame" src="getOrgListById.action" width="100%" height="450" frameborder="0"></iframe>
				</td>
			</tr>
		</table>
	</body>
</html>